From: cl349@firebug.cl.cam.ac.uk Date: Wed, 14 Sep 2005 19:34:13 +0000 (+0000) Subject: More syntactic sugar. X-Git-Tag: archive/raspbian/4.8.0-1+rpi1~1^2~16806^2~4 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=7c3dc1de8491d58bb15932230f62bc2ede9e32e6;p=xen.git More syntactic sugar. Signed-off-by: Christian Limpach --- diff --git a/tools/python/xen/xend/xenstore/xstransact.py b/tools/python/xen/xend/xenstore/xstransact.py index 7cabc25127..94a9bda1bd 100644 --- a/tools/python/xen/xend/xenstore/xstransact.py +++ b/tools/python/xen/xend/xenstore/xstransact.py @@ -105,6 +105,8 @@ class xstransact: return ret def gather(self, *args): + if len(args) and type(args[0]) != tuple: + args = args, ret = [] for tup in args: if len(tup) == 2: @@ -122,6 +124,8 @@ class xstransact: return ret def store(self, *args): + if len(args) and type(args[0]) != tuple: + args = args, for tup in args: if len(tup) == 2: (key, val) = tup